package vendas.dto;

import gminet.infra.dao.TransferObject;

public class Product extends TransferObject {

    private static final long serialVersionUID = -6145643265895340921L;

    private String name;
    private String description;
    private String imageFileName;
    private ActiveStatus activeStatus;

    public Product() {
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getResumeDescription() {
        String resumeDescription = "";
        if (getDescription() != null) {
            if (getDescription().length() <= 58) {
                resumeDescription = getDescription();
            } else {
                resumeDescription = getDescription().substring(0, 55) + "...";
            }
        }
        return resumeDescription;
    }

    public String getImageFileName() {
        return imageFileName;
    }

    public void setImageFileName(String imageFileName) {
        this.imageFileName = imageFileName;
    }

    public ActiveStatus getActiveStatus() {
        return activeStatus;
    }

    public void setActiveStatus(ActiveStatus activeStatus) {
        this.activeStatus = activeStatus;
    }

}
